package com.dk.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.dk.pojo.TbBail;
import com.dk.vo.TbBailVO;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

@Repository
public interface TbBailMapper extends BaseMapper<TbBail> {

    @Select("select DISTINCT * from tb_bail where uid = #{userid}")
    TbBailVO selectByUserId(Long userid);

    @Insert("INSERT INTO  tb_bail  VALUE(null,#{userid},#{cid},#{20})")
    int insertAll(Long userid, Long cid, Long num);
}
